package com.sxhuayuan.parking.controller.admin;

import com.sxhuayuan.parking.controller.BaseController;
import org.apache.commons.lang3.RandomStringUtils;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

@Controller("adminToolsController")
@RequestMapping("/tools")
public class ToolsController extends BaseController {

	@RequestMapping("/socket")
	public ModelAndView index() {
		ModelAndView mav = new ModelAndView("/tools/socket");
		return mav;
	}
	
	@RequestMapping("/chatroom")
	public ModelAndView chatroom() {
		ModelAndView mav = new ModelAndView("/tools/chatroom");
		mav.addObject("uid", RandomStringUtils.randomNumeric(6));
		return mav;
	}
}
